package edu.ccut.saturn.component;

import java.util.List;

/**
 * 记录了action组件、logic组件、component组件的基本信息的操作接口。
 * 
 * @author 谷钰
 * @version 1.0 2008.9.04
 * 
 */
public interface IComponentInfo extends XmlSerializable {
	
	/**
	 * 表示是否加载启动
	 */	
	public static final String LOAD_START_TRUE = "true";
	
	public static final String LOAD_START_FALSE = "false";

	public static final String KEY_SEPARATOR = "::";
	
	/**
	 * 表示间隔单位
	 */	
	public static final String REPEAT_UNIT_SECOND = "second"; //秒
	
	public static final String REPEAT_UNIT_MINUTE = "minute"; //分
	
	public static final String REPEAT_UNIT_HOUR = "hour"; //时
	
	public static final String REPEAT_UNIT_DAY = "day"; //天

	/**
	 * Get unique key.
	 * 
	 * @return
	 */
	public String getKey();

	/**
	 * Get symbolic name of bundle where the component in.
	 * 
	 * @return
	 */
	public String getBundleSymbolicName();

	/**
	 * Get complete Key. key = getBundleSymbolicName() + "::" + getKey()
	 * 
	 * @return
	 */
	public String getFullKey();

	/**
	 * Get component name
	 * 
	 * @return
	 */
	public String getName();

	/**
	 * Get component description
	 * 
	 * @return
	 */
	public String getDescription();

	/**
	 * Get {@link IParameterInfo} List
	 * 
	 * @return
	 */
	public List<IParameterInfo> getParameterInfos();
	
	/**
	 * Get component loadStart
	 * 
	 * @return
	 */
	public String getLoadStart(); 
	
	/**
	 * Create a component
	 * 
	 * @return
	 * @throws SaturnComponentException
	 */
	public IComponent createComponent() throws SaturnComponentException;
}
